import { createApp } from 'vue'


//1.引入全局的跟组件
import App from './App.vue'

//2.引入全局的样式文件
import './style.css'


//3.引入路由文件(router目录下的index.ts文件)
import router from './router'


//4.在项目中使用elment-Plus
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'

//5.在Vue3项目中使用pinia
import { createPinia } from 'pinia'
const pinia=createPinia()

//6.在Vue3中引入Mock接口的文件
import "./mock"


//7.在Vue3项目中使用导航守卫文件
import "@/router/guard"

const app=createApp(App)

app.use(router);
app.use(pinia);
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}
app.use(ElementPlus)
app.mount('#app')

